The 3 Most Common Intern Technical Interview Questions and How to Solve Them | Carla Codes

Поделиться
HTML-код
  • Опубликовано: 22 дек 2024

Комментарии •

  • @katiecates1695
    @katiecates1695 2 года назад +3

    I'm trying to practice at getting better at Python, and even though you are coding in Java, this was still very helpful! I was able to translate it over to Python. Thank you for the explanations and heads up on the type of questions!

  • @Liamllr
    @Liamllr 3 года назад +18

    2nd one why not use a hash map to clamp each value to its frequency, then iterate through hash map to find the largest one?
    O(n) runtime instead of n^2
    I agree with others that #3 could make use of memoization but if the point is to use recursion it is the textbook case of recursion

    • @Ron-zn6ws
      @Ron-zn6ws 3 года назад +3

      That's the optimal solution for that problem. As for the n-th Fibonacci problem, she could've used Dynamic Programming. You could've just created an array and then recursively call Fibonacci numbers and then stored them. When you need to find the n-th Fibonacci number, you could've just called from the array. That's technically recursion, because we're still using recursion to generate and therefore store. The complexity of that would've been pseudo-polynomial time, meaning O(n) and space is O(n).

    • @JH-hr6fw
      @JH-hr6fw 3 года назад +2

      I was just about to comment this. Just check if the hashmap has the array value as a key, if it doesnt: make it a key with the value of 1, otherwise increment the value of that key in the hashmap by one. After that its a basic traversal of the hashmap to check for the highest value's key.

  • @jon2886
    @jon2886 4 года назад +7

    This was awesome, good explanations. Looking forward to more content!

    • @givemeabreak2469
      @givemeabreak2469  4 года назад +2

      Thank you, I am glad you liked it! I will have 2 more problem explanations coming out later today :)

  • @carolinateixeira3143
    @carolinateixeira3143 3 года назад +3

    This is what I have been looking for!!!

  • @yasern4227
    @yasern4227 4 года назад +3

    Please discuss Graphs. I have a really hard time solving graph problems.

    • @givemeabreak2469
      @givemeabreak2469  4 года назад +2

      Sure! I will add that to my list of videos to make :)

  • @ChristosNikolis
    @ChristosNikolis 4 года назад +3

    Amazing job! Thank you, once more. It seems i'm not so far off!!! woo-hoo :-)

  • @khatarnak2648
    @khatarnak2648 3 года назад

    You are very helpful to me 😊

  • @varunmanjunath6204
    @varunmanjunath6204 3 года назад +1

    These questions are too simple to be asked.

    • @givemeabreak2469
      @givemeabreak2469  3 года назад +7

      I interned at 3 large, well known companies and one seed-stage start up. During each interview process, I was asked at least one of these questions.

    • @ZeeshanAli-nm7eq
      @ZeeshanAli-nm7eq 3 года назад

      @@givemeabreak2469 ahan, thanks for sharing that info...